home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_03_02
/
3n02045a
< prev
next >
Wrap
Text File
|
1991-12-15
|
2KB
|
40 lines
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-Begin Listing 5-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
/*****************************************************/
/* cursor.c */
/* -- Routine to change the cursor even if a dialog */
/* box is present. */
/*****************************************************/
VOID
MySetCursor(HWND hwnd, WORD wm, WORD wmp, DWORD lwmp,
HCURSOR hcsr)
/*****************************************************/
/* -- Handle the WM_SETCURSOR message. */
/* -- hwnd : Window receiving message. */
/* -- wm : Message number. */
/* -- wmp : Word sized message parameter. */
/* -- lwmp : Long word sized message parameter. */
/* -- hcsr : Cursor to display. Use NULL for */
/* default. */
/*****************************************************/
{
if (hcsr == hcsrNull)
{
DefWindowProc(hwnd, wm, wmp, lwmp);
}
else
{
/* Don't prevent DefWindowProc() form */
/* performing its hand in the kludge to make */
/* this application the active one! */
if (HIWORD(lwmp) == WM_LBUTTONDOWN &&
LOWORD(lwmp) == HTERROR)
DefWindowProc(hwnd, wm, wmp, lwmp);
SetCursor(hcsr);
}
}
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-End Listing 5-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=